import 'package:flutter/material.dart';

void main() {
  runApp(MaterialApp(
      home: Scaffold(
    appBar: AppBar(
      title: const Text("你好flutter"),
    ),
    body: const MyApp(),
  )));
}

class MyApp extends StatelessWidget {
  const MyApp({super.key});

  @override
  Widget build(BuildContext context) {
    return Column(
      children: [
        Center(
            child: Container(
          alignment: Alignment.center,
          width: 200,
          height: 200,
          decoration: const BoxDecoration(
            color: Colors.yellow,
          ),
          margin: const EdgeInsets.all(20),
        )),
        Center(
          child: Container(
            alignment: Alignment.center,
            width: 200,
            height: 40,
            padding: const EdgeInsets.fromLTRB(20, 0, 20, 0),
            decoration: BoxDecoration(
                color: Colors.blue, borderRadius: BorderRadius.circular(20)),
            child: const Text(
              "按钮",
              style: TextStyle(fontSize: 20, color: Colors.white),
            ),
          ),
        ),
      ],
    );
  }
}
